﻿using AnesSystem.Models;
using AnesSystem.Services;
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace AnesSystem.ViewModels
{
    class ConfigUnitDataGridViewModel : BaseViewModel<ConfigUnitDataGridViewModel>
    {

        #region Variables

        private ObservableCollection<ConfigUnitsModel> _configUnitsModel = new ObservableCollection<ConfigUnitsModel>();

        #endregion

        #region Constructor

        public ConfigUnitDataGridViewModel()
        {
            initConfigUnitsModel();
        }

        #endregion

        #region Properties

        public ObservableCollection<ConfigUnitsModel> ConfigUnitsModel
        {
            get
            {
                return _configUnitsModel;
            }

            set
            {
                _configUnitsModel = value;
                RaisePropertyChanged("ConfigDepartmentsModels");
            }
        }

        #endregion

        #region Event

        #endregion

        #region Private Methods
        private void initConfigUnitsModel()
        {
            IEnumerable<ConfigUnitsModel> list = ConfigUnitsModelService.Instance.FindAll();
            foreach (var item in list)
            {
                _configUnitsModel.Add(item);
               
            }
        }

      
        #endregion

        #region Public/Protected Methods


        #endregion

        #region EventHandlers

        #endregion

        #region Command

        #region ChangeDoctorCommand

        #endregion

        #region OpenPopupCommand

        #endregion
        #endregion

    }
}
